from django import forms
from .models import Comment, Post


class EmailPostForm(forms.Form):
    name = forms.CharField(max_length=25)
    toemail = forms.EmailField()
    comments = forms.CharField(required=False, widget=forms.Textarea)


class CommentForm(forms.ModelForm):
    class Meta:
        model = Comment
        fields = ('username', 'email', 'content')


class PostForm(forms.ModelForm):
	class Meta:
		model = Post
		fields = ('title', 'status')